﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace GA.Server.DatabaseManager
{
    [Serializable]
    [AttributeUsage(AttributeTargets.Property)]
    public class DatabaseFieldAttribute : Attribute
    {
        public bool IsKey { get; set; }
        public string FieldName { get; set; }
        public bool IsQuoted { get; set; }
        public bool IsIdentity { get; set; }

        public DatabaseFieldAttribute()
        {
            FieldName = string.Empty;
            IsKey = false;
            IsQuoted = false;
            IsIdentity = false;
        }

        public DatabaseFieldAttribute(string fieldName)
        {
            FieldName = fieldName;
            IsKey = false;
            IsQuoted = false;
            IsIdentity = false;
        }
    }
}
